<template>
	<view class="down_wrap" v-if="getINfo">
		<!--		聊天框-->
		<view v-show="view==2">
			<!--		聊天内容-->
			<view class="down_wrapCentert">
				<view @click="returnClick" class="img" style="width: 10%;margin-top: 15px;">
					<span class="right-arrow"></span>
				</view>
				<view style="margin: 15px auto;margin-top: 29px;">

					<view
						style="font-size: 36rpx;font-weight: 600;letter-spacing:2px;color:#fff;line-height: 1;text-align: center;">
						{{optionInfo.userType==2? optionInfo.userNickname:optionInfo.userName }}
					</view>
					<view v-if="optionInfo.userType==2"
						style="line-height: 1;margin-top: 10rpx;text-align: center; font-size: 30rpx;font-weight: 600;letter-spacing:2px;color:#fff">
						{{optionInfo.fromPosition==myInfo?optionInfo.toPosition:optionInfo.fromPosition}}
					</view>

				</view>
				<view @click="toSetUp()">
					<span style="margin-right: 10px;margin-top: 5px;font-size: 34px;">...</span>
				</view>
			</view>
			<view class="tips" v-show="setupFlag">
				<view class="owner">
					<view @click="jubao" style="padding: 10px 8px;text-align: center;font-size: 15px;font-weight: 600;">
						<text>举报</text>
					</view>
				</view>
			</view>

			<view>

				<scroll-view id="scollDIV" show-scrollbar="true" class="chat-window" scroll-y="false"
					style="background-color: #F1F1F1;" :style="{height: style.contentViewHeight-15 + 'px'}"
					:scroll-with-animation="false" :scroll-top="scrollTop" @scrolltoupper="scrolltoupper"
					@scroll="scrollY">
					<br>
					<view class="" id="lastMsg">
						<view v-for="(item, index) in userInfo.messageList" :key="index" style="padding-bottom: 20rpx;">
							<!-- 上个消息与本次消息相差时间大于5分钟则展示时间 -->
							<!-- <view style="text-align: center;font-size: 14px;color: #999999;"
								v-if="item.timeFlag==true &&item.beginTime!=null && item.beginTime!=''  ">{{item.beginTime}}
							</view> -->
							<view style="text-align: center;font-size: 14px;color: #999999;"
								v-if="item.timeFlag&&String(item.beginTime).length>0">
								<view class="" v-if="String(item.beginTime).length>10">
									<view class="" v-if="currentDay==String(item.beginTime).substring(0,10)">
										{{String(item.beginTime).substring(10,16)}}
									</view>
									<view class="" v-else-if="currentYear==String(item.beginTime).substring(0,4)">
										{{String(item.beginTime).substring(5,16)}}
									</view>
									<view class="" v-else>
										{{String(item.beginTime).substring(0,16)}}
									</view>
								</view>
								<view class="" v-else>
									{{String(item.beginTime).substring(0,6)}}
								</view>


							</view>
							<!-- 对方 -->
							<view class="word" v-if="item.mineMsg=='0'">
								<image @click="toSetUp2()"
									style="width: 40px; height: 40px;border-radius: 50%;margin-top:22px;margin-left: 48rpx"
									v-if="item.headImg!=null" mode="aspectFill" :src="item.headImg"></image>
								<image @click="toSetUp2()"
									style="width: 40px; height: 40px;border-radius: 50%;margin-top:22px;margin-left: 48rpx"
									v-if="item.headImg==null" mode="aspectFill"
									src="https://clhy-img.oss-cn-beijing.aliyuncs.com/logo/avatar.jpg"></image>
								<view class="info2">
									<p class="time2"></p>
									<view
										style="max-width: 200px;text-align: left;border-radius: 10rpx;padding: 10px;font-size: 14px;margin-right: 10px;background: #A3C3F6;margin-top: 5px;background-color: #F8F8F8;word-break:break-all; word-wrap:break-word;">
										{{item.message}}
									</view>

								</view>
							</view>
							<!-- 我的 -->
							<view class="word-my" v-else>
								<view class="info">
									<p class="time"></p>
									<view class="info-content"
										style="border-radius: 10rpx;background-color: #4CD964;word-break:break-all; word-wrap:break-word;">
										{{item.message}}
									</view>
								</view>
								<image @click="toSetUp()"
									style="width: 40px; height: 40px;border-radius: 50%;margin-top:22px;margin-right: 48rpx"
									v-if="item.headImg!=null" mode="aspectFill" :src="item.headImg"></image>
								<image @click="toSetUp()"
									style="width: 40px; height: 40px;border-radius: 50%;margin-top:22px;margin-right: 48rpx"
									v-if="item.headImg==null" mode="aspectFill"
									src="https://clhy-img.oss-cn-beijing.aliyuncs.com/logo/avatar.jpg"></image>
							</view>
						</view>

					</view>


				</scroll-view>
			</view>
			<view class="search-box-l  u-flex">
				<view class="u-flex-1 u-m-r-10 ">
					<u-input style='text-indent: 30rpx;' v-model="message" :clearable="false" placeholder="请输入内容" />
				</view>
				<view class="search-btn">
					<u-button @click='sendMessage' shape='circle' style="color: #ffffff;">发送</u-button>
				</view>
			</view>
		</view>

	</view>
</template>

<script>
	import url_config from '@/common/config.js'
	export default {
		data() {
			return {
				setupFlag: false,
				// 聊天页面时时滚动样式
				style: {
					pageHeight: 0,
					contentViewHeight: 0,
					footViewHeight: 90,
					mitemHeight: 0
				},
				ws: {}, //websocket对象,,,无用
				scrollTop: 0,
				message: null,
				view: 2, //1.展示人，2.展示聊天框
				input2: null, //搜索内容
				userLoggerInfo: {}, //登录人信息
				userInfo: {},
				userInfo2: {},
				headName: '私信',
				userList: [], //通知人
				messageInfo: {
					message: null, //内容
					user_id: null, //被通知人
				}, //传给后台的对象
				optionInfo: null,
				getINfo: false,
				pageIndex: 1,
				messageLast: null,
				newHeight: null,
				pageLength: 0,
				haspage: true,
				currentDay: null,
				currentYear: null
			}
		},
		onLoad(option) {
			var obj = JSON.parse(option.val)

			this.optionInfo = obj;
			console.log("optionInfo===============", this.optionInfo);
			var obj2 = JSON.parse(option.logerInfo)
			this.userLoggerInfo = obj2;

			// this.h5ScrollHeight();
			// this.appScrollHeight();
			console.log("obj1，obj2", obj, obj2);
			this.updateDot(obj)


		},

		created() {

			const res = uni.getSystemInfoSync(); //获取手机可使用窗口高度     api为获取系统信息同步接口
			this.style.pageHeight = res.windowHeight;
			console.log(res.windowHeight)
			this.style.contentViewHeight = res.windowHeight - uni.getSystemInfoSync().screenWidth / 750 * (100) -
				70; //像素   因为给出的是像素高度 然后我们用的是upx  所以换算一下
			console.log("app高度：" + this.style.contentViewHeight)
			this.scrollToBottom(); //创建后调用回到底部方法

		},



		onShow() {
			// this.triggerChatAudio();//音频
			this.myInfo = uni.getStorageSync('myPosition')
			if (this.myInfo) {
				this.getMessageList()
			}
			console.log('hourseStrhourseStr', this.myInfo)
			this.creatSocket();
			this.getTime()
			this.updateScrollTop()
			//进入页面，消除红点
		},
		methods: {
			scrollY(e) {
				this.newHeight = e.detail.scrollHeight
			},
			updateScrollTop() {
				this.$nextTick(() => {
					setTimeout(() => {
						const query = uni.createSelectorQuery().in(this)
						console.log('lastMsglastMsg')
						// 视口元素
						query.select('#scollDIV').boundingClientRect()
						// 列表
						query.select('#lastMsg').boundingClientRect()
						query.exec(res => {
							console.log(res, 'res======')
							if (res[0].height < res[1].height) {
								this.scrollTop = res[1].height - res[0].height + 20
								console.log('this.scrollTop', this.scrollTop, 'this.scrollTop')
							}
						})
					}, 1800)

				})

			},
			scrolltoupper() {
				console.log(this.pageIndex)
				if (this.haspage) {
					this.pageIndex += 1
					this.getMessageList()
				}
				// this.$nextTick(() => {
				// setTimeout(() => {
				// })

				// }, 0)

			},
			// 获取聊天信息getmessageInfoApi {"userId":3770,"byUserId":6858,"pageIndex":0,"recordSize":10}
			getMessageList() {
				let toPosition = null
				let fromPosition = null
				if (this.optionInfo.reqSource == 'list') {
					if (this.optionInfo.fromPosition) {
						fromPosition = this.optionInfo.fromPosition
					}
					if (this.optionInfo.toPosition) {
						toPosition = this.optionInfo.toPosition
					}
				} else {
					fromPosition = this.myInfo
					if (this.optionInfo.position) {
						toPosition = this.optionInfo.position
					}
				}



				console.log('2222===', this.myInfo)



				let params = {
					userId: uni.getStorageSync(('rawData')).userId,
					byUserId: this.optionInfo.userId,
					pageIndex: this.pageIndex - 1,
					recordSize: 10,
					appType: 2, //业主端：5
					userType: this.optionInfo.userType,
					fromPosition: fromPosition,
					toPosition: toPosition,
					orgId: uni.getStorageSync('projectItem').orgId

				}
				uni.showLoading({
					title: '数据加载中'
				})
				this.$request.api.getmessageInfoApi(params).then(res => {
					uni.hideLoading()
					this.getINfo = true
					console.log("res", res.data.data.dataList);
					if (this.pageIndex == 1) {
						this.userInfo.messageList = res.data.data.dataList
					} else {
						this.userInfo.messageList = [...res.data.data.dataList, ...this.userInfo.messageList]
					}
					console.log("this.userInfo.messageList.length", this.userInfo);
					this.messageLast = this.userInfo.messageList.length - 1
					console.log('res========this.userInfo.messageList', res.data.data.dataList)
					console.log('resmessageList========this.userInfo.messageList', this.userInfo.messageList)
					console.log("this.pageIndex--------", this.pageIndex, (this.pageIndex + 1) * 10 > res.data.data
						.total);
					if ((this.pageIndex + 1) * 10 > res.data.data.total) {
						this.haspage = false
					}
					console.log("this.haspage", this.haspage);
					this.$forceUpdate();
					this.pageLength = res.data.data.dataList.length

					//定位
					this.scrollTop = res.data.data.dataList.length * 120
					console.log(this.newHeight, 'this.scrollTop{{{{{{{{{{{}}}}}}}}}}}', this.scrollTop)
				})
			},
			clickContent() {
				if (this.setupFlag) {
					this.setupFlag = !this.setupFlag;
				}
			},
			scrollToBottom: function() {

				let that = this;
				if (this.userInfo.messageList) {
					var count = this.userInfo.messageList.length;
					console.log(count)
					that.scrollTop = count * 120; //不规范的写法，有点离谱
					console.log(that.scrollTop)
				}


			},
			toSetUp() {
				if (this.setupFlag == false) {
					this.setupState = 1;
					this.setupFlag = true;
				} else {

					this.setupFlag = false;
				}
			},
			//举报
			jubao(val) {
				by_user_id: val.user_id,
				uni.navigateTo({
					url: '/pages/mine/reportLot?by_user_id=' + this.userInfo.user_id
				})
			},
			scrollToBottom2: function() {

				let that = this;

				var count = this.userInfo.messageList.length;
				console.log(count)
				that.scrollTop = 3000; //不规范的写法，有点离谱


			},


			h5ScrollHeight() {
				this.$nextTick(() => {
					let msg = document.getElementById('scollDIV') // 获取对象
					console.log("h5scroll信息！！！！！" + msg)
					console.log("h5scroll高度！！！！！" + msg.scrollHeight)
					msg.scrollTop = msg.scrollHeight // 滚动高度

				})
			},
			//发送消息
			sendMessage() {
				if (this.message == null || this.message == '') {
					return;
				}
				//判断时间相差多少分钟，超过3分钟不展示时间
				var nowTime = new Date();
				var flag = true;
				if (this.userInfo.messageList && this.userInfo.messageList[this.userInfo.messageList.length - 1] != null) {
					var betime2 = this.userInfo.messageList[this.userInfo.messageList.length - 1].beginTime;
					console.log('betime2betime2betime2', String(betime2).length)
					if (String(betime2).length == 5) {
						betime2 = this.currentDay + '  ' + betime2
					}
					console.log('betime2betime2betime2', betime2)
					if (betime2 != null) {
						var dateDiff = nowTime.getTime() - new Date(betime2).getTime();
						var leave1 = dateDiff % (24 * 3600 * 1000); //计算天数后剩余的毫秒数
						var leave2 = leave1 % (3600 * 1000); //计算小时数后剩余的毫秒数
						var minutes = Math.floor(leave2 / (60 * 1000)); //计算相差分钟数
						if (minutes < 3) {
							flag = false;
						}
					}
				}

				if (!this.userInfo.messageList) {
					this.userInfo.messageList = []
				}

				console.log('falsefalsefalse', flag, this.userInfo)
				this.userInfo.messageList.push({
					userName: this.userLoggerInfo.userName,
					message: this.message,
					beginTime: this.getTime(),
					headImg: this.userLoggerInfo.userHeadPortrait,
					mineMsg: '1',
					beginTime2: this.getTime2(nowTime),
					timeFlag: flag
				})
				let that = this;
				this.messageInfo.message = this.message;
				console.log("this.userInfo", this.userInfo);
				// let hourseStr = uni.getStorageSync('projectItem')
				// this.messageInfo.fromPosition = hourseStr.buildDistrictCode + '-' + hourseStr.buildTowerCode + '-' +
				// 	hourseStr.roomUnitNumber + '-' + hourseStr.roomCode
				this.messageInfo.fromPosition = uni.getStorageSync('myPosition')
				this.messageInfo.user_id = this.optionInfo.userId;
				this.messageInfo.orgId = uni.getStorageSync('projectItem').orgId
				if (this.optionInfo.position) {
					this.messageInfo.toPosition = this.optionInfo.position
				} else if (this.messageInfo.fromPosition == this.optionInfo.fromPosition) {
					this.messageInfo.toPosition = this.optionInfo.toPosition
				} else if (this.messageInfo.fromPosition == this.optionInfo.toPosition) {
					this.messageInfo.toPosition = this.optionInfo.fromPosition
				}
				var message = JSON.stringify(this.messageInfo);
				console.log("消息发送成功", message);
				that.ws.send({
					data: message,
					async success() {
						console.log("消息发送成功");
					},

				});
				this.updateScrollTop()
				this.message = null;
				// this.appScrollHeight();
				// this.h5ScrollHeight();





			},
			getTime2(date) {
				//年
				var year = date.getFullYear();
				//月
				var month = date.getMonth() + 1;
				//日
				var strDate = date.getDate();
				//时
				var hour = date.getHours();
				//分
				var minute = date.getMinutes();
				//秒
				var second = date.getSeconds();

				month = month > 9 ? month : '0' + month

				strDate = strDate > 9 ? strDate : '0' + strDate

				hour = hour > 9 ? hour : '0' + hour

				minute = minute > 9 ? minute : '0' + minute

				second = second > 9 ? second : '0' + second

				var newdata = year + '-' + month + '-' + strDate + ' ' + hour + ':' + minute + ':' + second

				return newdata;
			},
			getTime() {
				var _this = this;
				let yy = new Date().getFullYear();
				let mm = new Date().getMonth() + 1;
				let dd = new Date().getDate();
				let hh = new Date().getHours();
				let mf = new Date().getMinutes() < 10 ? '0' + new Date().getMinutes() : new Date().getMinutes();
				let ss = new Date().getSeconds() < 10 ? '0' + new Date().getSeconds() : new Date().getSeconds();
				_this.gettime = hh + ':' + mf;
				console.log(this.gettime)
				if (mm < 10) {
					mm = '0' + mm
				}
				if (dd < 10) {
					dd = '0' + dd
				}
				_this.currentDay = yy + '-' + mm + '-' + dd
				_this.currentYear = yy
				return this.gettime;
			},
			returnClick() {
				uni.$emit("getUserList")
				uni.switchTab({
					url: '/pages/news/newsList'
				})
			},
			//消除红点消息
			updateDot(val) {

				console.log('{{{{{{dfd}}}}}}', val)
				console.log("消除红点")
				let position = uni.getStorageSync('myPosition')
				let fromPosition
				let toPosition
				if (val.userType == 2) {
					if (val.fromPosition == position) {
						fromPosition = val.toPosition
						toPosition = val.fromPosition
					} else {
						fromPosition = val.fromPosition
						toPosition = val.toPosition
					}
				} else {
					fromPosition = position
				}

				this.$request.api.updateDotMessagechant({
					user_id: uni.getStorageSync('rawData').userId,
					by_user_id: val.userId,
					toPosition: toPosition,
					fromPosition: fromPosition,
					orgId: uni.getStorageSync('projectItem').orgId
				}).then(res => {
					console.log("消除红点完毕")
				})
			},

			//建立websocket链接
			creatSocket: function() {
				let that = this;
				// 创建一个this.socketTask对象【发送、接收、关闭socket都由这个对象操作】
				let url = url_config.split("://")[1];
				let a
				if (url == "www.515f.com/api") {
					a = "skt.515f.com"
				} else if (process.env.NODE_ENV == 'development') {
					a = url
				} else {
					//#ifdef H5
					const ipAddress = window.location.href
					const urlObject = new URL(ipAddress)
					a = url.split(":")[0] + ':' + urlObject.port + '/api'
					//#endif
					//#ifdef APP-PLUS
					a = url
					//#endif
				}
				// optionInfo
				// a = "ws://" + a + "/websocket/venus/5/" + uni.getStorageSync('rawData').userId;
				// a = "ws://" + a + "/websocket/venus?appType=2&userType=2&userId=" + uni.getStorageSync('rawData')
				// 	.userId;
				a = `ws://${a}/websocket/venus?appType=2&userType=${this.optionInfo.userType}&userId=${uni.getStorageSync('rawData')
					.userId}`

				console.log("websocket连接地址", a);
				that.ws = uni.connectSocket({
					// 【非常重要】必须确保你的服务器是成功的,如果是手机测试千万别使用ws://127.0.0.1:9099【特别容易犯的错误】
					// url: "ws://39.97.174.161:8900/websocket/venus/5/" + uni.getStorageSync(
					// 	'rawData').userId,
					url: a,
					// url: "ws://192.168.101.82:8900/websocket/venus2/"+ JSON.parse(uni.getStorageSync('userData')).userId,//本地
					// url: "ws://192.168.101.148:8900/websocket/venus2/" + JSON.parse(uni.getStorageSync(
					// 	'userData')).userId,
					success(data) {
						console.log("websocket连接成功");
					},
				});
				//监听websocket连接打开方法
				// that.ws.onopen = function() {
				// 	that.ws.send('TaylorSwift');
				// 	console.log('打开websocket');
				// 	//调用keepalive方法（不一定都需要调用此方法，可注释）
				// 	// that.keepAlive()
				// };
				that.ws.onOpen((res) => {
					console.log("unapp--WebSocket连接正常打开中...！");
				})

				//监听websocket错误方法
				that.ws.onerror = function(ev) {
					console.log('连接已出错...');
					//延迟执行重连
					setTimeout(() => {
						that.creatSocket();
					}, that.$global.delay);
				};
				//监听websocket关闭方法
				// 这里仅是事件监听【如果socket关闭了会执行】
				that.ws.onClose(() => {
					console.log("已经被关闭了")
				})

				// 注：只有连接正常打开中 ，才能正常收到消息
				that.ws.onMessage((res) => {
					console.log("收到服务器内容：" + res.data);
					uni.$emit('getUserList')
					var obj = JSON.parse(res.data) //将websocket的string数据转换成对象
					func1(obj)
				});

				let func2 = function func3(val) {
					console.log(val.user_id, this.optionInfo.userId);
					if (val.user_id == this.optionInfo.userId) {
						//判断时间相差多少分钟，超过3分钟不展示时间
						var nowTime = new Date();
						var flag = true;
						if (this.userInfo.messageList[this.userInfo.messageList.length - 1] != null) {
							var betime2 = this.userInfo.messageList[this.userInfo.messageList.length - 1]
								.beginTime2;
							console.log(betime2)
							if (betime2 != null) {
								console.log("判断是否展示时间")
								var dateDiff = nowTime.getTime() - new Date(betime2).getTime();
								var leave1 = dateDiff % (24 * 3600 * 1000); //计算天数后剩余的毫秒数
								var leave2 = leave1 % (3600 * 1000); //计算小时数后剩余的毫秒数
								var minutes = Math.floor(leave2 / (60 * 1000)); //计算相差分钟数
								if (minutes < 3) {
									flag = false;
								}
								console.log("判断是否展示时间完毕")
							}
						}



						// this.updateDot(val)
						console.log("展示收到的信息")
						this.userInfo.messageList.push({
							userName: val.userName,
							message: val.message,
							beginTime: val.begin_time,
							headImg: val.userHeadPortrait,
							mineMsg: '0',
							beginTime2: this.getTime2(nowTime),
							timeFlag: flag
						})
						this.updateScrollTop()
						// console.log("this.scrollTop",this.scrollTop);
						// this.scrollTop+=120
						// console.log("this.scrollTop",this.scrollTop);
						this.$forceUpdate()
						console.log("展示收到的信息完毕", this.userInfo.messageList)
						// this.appScrollHeight();
						// this.h5ScrollHeight();
					}
				}
				let func1 = func2.bind(this);


			},
		}

	}
</script>

<style lang="scss" scoped>
	// .u-input__input{
	// 	min-height: 40px !important;
	// }
	/deep/.u-input__input[data-v-460c1d26] {
		font-size: 14px;
		color: #303133;
		min-height: 40px !important;
	}

	.down_wrap {
		.tips {
			position: absolute;
			right: 0;
			margin-top: 0px;
			z-index: 3;
			box-shadow: 0px 6px 20px 0px rgba(155, 155, 155, 0.5);

			.owner {
				width: 160rpx;
				height: 80rpx;
				border: 1px solid #fff;
				background: rgb(255, 255, 255);
				border-bottom-right-radius: 10px;
				border-bottom-left-radius: 10px;
			}

			.owner-center {
				padding: 10px 8px;
				text-align: center;
				font-size: 15px;
				font-weight: 600;
				border-bottom: 1px solid #a0cfff;
			}
		}

		.down_wrapCentert {
			display: flex;
			width: 100%;
			line-height: 80px;
			height: 80px;
			// background: linear-gradient(198deg, rgb(30, 127, 24) 0%, rgb(102, 216, 95) 53%, rgb(107, 157, 103) 100%);
			background-image: url(https://clhy-img.oss-cn-beijing.aliyuncs.com/ownerImage/messageback.pic.jpg);
			flex-direction: row;
			align-items: center;
			padding-top: 20px;
		}
	}

	.right-arrow {
		display: inline-block;
		position: relative;
		width: 28px;
		height: 28px;
		margin-right: 20px;
		top: 13px;
	}

	.right-arrow::after {
		display: inline-block;
		content: " ";
		height: 13px;
		width: 13px;
		border-width: 0 0 3px 3px;
		/* border-color: #0177ff; */
		border-style: solid;

		-webkit-transform: matrix(0.71, 0.71, -0.71, 0.71, 0, 0);
		transform: matrix(0.71, 0.71, -0.71, 0.71, 0, 0);
		position: absolute;
		// top: 50%;
		left: 31px;
	}

	.item {
		margin-top: 10px;
		margin-right: 40px;
	}

	.chat-content {
		width: 100%;
		padding: 20px;
	}

	.word {
		display: flex;
		margin-bottom: 20px;
		box-sizing: border-box;
	}

	.info2 {
		margin-left: 10px;
	}

	.time2 {
		font-size: 12px;
		color: rgba(51, 51, 51, 0.8);
		margin: 0;
		height: 20px;
		line-height: 20px;
		margin-top: -5px;

	}

	.info-content2 {
		max-width: 70%;
		padding: 10px;
		font-size: 14px;
		float: right;
		margin-right: 10px;
		position: relative;
		margin-top: 8px;
		background: #fff;
		text-align: left;
	}

	.info-content2::before {
		position: absolute;
		left: -8px;
		top: 8px;
		content: '';
		border-right: 10px solid #FFF;
		border-top: 8px solid transparent;
		border-bottom: 8px solid transparent;
	}

	.info-content {
		max-width: 70%;
		padding: 10px;
		font-size: 14px;
		float: right;
		margin-right: 10px;
		position: relative;
		margin-top: 8px;
		background: #A3C3F6;
		text-align: left;
	}

	.info-content::after {
		position: absolute;
		right: -8px;
		top: 8px;
		content: '';
		border-left: 10px solid #4CD964;
		border-top: 8px solid transparent;
		border-bottom: 8px solid transparent;
	}



	.word-my {
		display: flex;
		justify-content: flex-end;
		margin-bottom: 20px;
	}


	.info {
		width: 90%;
		margin-left: 10px;
		text-align: right;
	}

	.time {
		font-size: 12px;
		color: rgba(51, 51, 51, 0.8);
		margin: 0;
		height: 20px;
		line-height: 20px;
		margin-top: -5px;
		margin-right: 10px;
	}

	.search-box-l {
		width: calc(100% - 60rpx);
		height: 80rpx;
		margin: 10rpx auto 15rpx;
		border: 2rpx solid rgb(102, 216, 95);
		border-radius: 36rpx;
		border-right: none;

	}

	.search-btn {
		width: 153rpx;
		height: 80rpx;
		margin-top: -2rpx;

		.u-btn {
			width: 100%;
			height: 102%;
			color: #fff;
			background: linear-gradient(198deg, rgb(30, 127, 24) 0%, rgb(102, 216, 95) 53%, rgb(107, 157, 103) 100%);
			font-size: 32rpx;
			// border: 1px solid #66d85f;
			box-sizing: border-box;
		}
	}

	.search-row {
		border-bottom: 2rpx solid #eee;
		height: 82rpx;
	}

	.search-cont-box {
		border-bottom: 2rpx solid #eee;
	}

	.send-input {
		position: fixed;
		bottom: 0;
		width: 100%;
		height: 130rpx;
		background-color: #fff;
		display: flex;
		align-items: baseline;
		padding-top: 10px;
		padding-bottom: 100rpx;
	}
</style>